//created by: Justina Lee

Ext.define("MajorProjectSenchaTouch.store.EResourcesMusic", {
    extend: "Ext.data.Store",
    xtype: 'eResourcesMusicStore',
    requires:[
    'Ext.data.proxy.JsonP'
    ],
    config:{
        model: "MajorProjectSenchaTouch.model.EResource",
        proxy:{
            type: 'jsonp',
            url: MajorProjectSenchaTouch.app.serverUrl + 'eresources/eresourcesmusiclist',
            reader:{
                type: 'json',
                rootProperty: 'eResources'
            }
        },
        sorters:[
        {
            property: 'name',
            direction: 'ASC'
        }
        ],
        grouper: function(record){
            return record.get('categoryName');
        },
        groupDir: 'DESC'
    }
});